<!DOCTYPE HTML>
<html>

<head>
    <title>物料领用</title>
    <meta charset="utf-8">
    <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
    <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
    <link rel="stylesheet" type="text/css" href="../css/api.css" />
    <link rel="stylesheet" type="text/css" href="../css/aui.css" />
    <link rel="stylesheet" type="text/css" href="../css/aui-pull-refresh.css" />
    <link rel="stylesheet" type="text/css" href="../css/iconfont.css" />
    <link rel="stylesheet" type="text/css" href="./css/headersearch.css" />
    <link rel="stylesheet" type="text/css" href="./css/comm.css" />
    <link rel="stylesheet" type="text/css" href="css/chooseserviceuser.css" />
    <link rel="stylesheet" type="text/css" href="./css/chooseckproduct_frm.css" />
    <style>
    </style>
</head>

<body>
    <div id="app" v-cloak>
        <section class="aui-content contentBox">
            <div v-on:click="doHideSearch()" v-if="showsearch" class="maskbg">
            </div>

            <!-- 搜索 -->
            <div class="aui-searchbar" id="search">
                <div class="aui-searchbar-input aui-searchbar-input-white aui-border-radius">
                    <i class="icon iconfont icon-sousuo"></i>
                    <input v-model="form.keywords" type="search" placeholder="物料名称" id="search-input">
                    <div class="aui-searchbar-clear-btn" style="top:12px">
                        <i class="icon iconfont icon-guanbi"></i>
                    </div>
                </div>
                <div class="aui-searchbar-btn" tapmode></div>
            </div>

            <div v-if="list.length>0" v-for="(item,index) in list" class="aui_list boxarea mb20">
                <div class="">
                    <div class="aui-list">
                        <div class="aui-list-item">
                            <div class="aui-list-item-inner " v-bind:class="{'border-bottomLine':item.isopen}" >
                                <div class="aui-list-item-title">
                                    <i v-if="item.isopen" v-on:click="showMoreOpen(item)" class="icon iconfont icon-jian new-icon-postion"></i>
                                    <i v-if="!item.isopen" v-on:click="showMoreOpen(item)" class="icon iconfont icon-jia new-icon-postion"></i>
                                    {{item.text}}
                                </div>
                            </div>
                        </div>
                        <div v-if="item.isopen">
                            <div v-for="(item2,index2) in item.children" class="aui-list-item" style="display: block;" >
                                <div class="aui-media-list-item-inner ptb " v-bind:class="{'border-bottomLine':index2<item.children.length-1}">
                                    <div class="aui-list-item-inner aui-padded-t-10 aui-padded-b-10" style="display: block;">
                                        <div class="aui-list-item-text">
                                            <div class="aui-list-item-title">
                                                {{item2.text}}<span v-if="item2.modelno!=''" class="list-shu">|</span>{{item2.modelno}}{{item2.Unit}}
                                            </div>
                                            <div class="aui-list-item-right" style="width:160px;">
                                                <span v-if="item2.Quantity>0" v-on:click="delQuantity(item2)" class="new-jian-bg"> <i class="icon iconfont icon-jian  text-blue fz12 "></i></span>
                                                <a v-if="item2.Quantity>0" class="phone_a">
                                                    <input type="number" name="" v-model="item2.Quantity"  v-on:change="onChangeQuantity(item2)">
                                                </a>
                                                <span v-on:click="addQuantity(item2)" class="new-jia-bg fr"><i class="icon iconfont icon-jia fff fz12"></i></span>
                                            </div>
                                        </div>
                                        <span v-if="item2.SellPrice>=0" class="sellPriceSty">销售单价：{{item2.SellPrice}}元</span>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>

                </div>
            </div>

            <div v-if="list.length>0" class="notodayList ccc">
                没有更多内容
            </div>

        </section>


        <!--<div class="aui-content headerBox">
        <div class="aui-searchbar" id="search">
            <div class="aui-searchbar-input aui-border-radius">
                <i class="aui-iconfont aui-icon-search"></i>
                <input v-model="form.keywords" type="search" placeholder="请输入区域名称" id="search-input">
                <div class="aui-searchbar-clear-btn">
                    <i class="icon iconfont icon-guanbi"></i>
                </div>
            </div>
            <div class="aui-searchbar-btn" tapmode></div>
        </div>
    </div>
    <ul class="mytree level1">
        <li v-for="item2 in list">
            <span class="name_span department">{{item2.text}}</span>
            <ul class="level2">
                <li class="name_phone" v-for="item3 in item2.children">
                    <span v-on:click="do_choose(item3)" class="choosespan">
                        <input type="checkbox" class="aui-checkbox" v-bind:checked="item3.ischecked">
                    </span>
                    <span v-on:click="do_choose(item3)" class="name_span" v-on:click="do_choose(item3,item2.children)">{{item3.text}}
                        <span style="padding:0;" v-if="item3.modelno">
                          ({{item3.modelno}})
                        </span>
                    </span>
                    <a class="phone_a">
                        <input type="number" name="" placeholder="请输入" v-model="item3.Quantity">
                    </a>
                </li>
            </ul>
        </li>
    </ul>
    <div class="aui_bottom">
        <div class="aui_bottombtn" v-on:click="do_save()">确认</div>
    </div>-->

        <div v-if="showchoose" class="choose-list">
            <div class="choose-header border-bottomLine">
                已选：{{totalQuantity}}
                <label v-on:click="showChooseAll()" class="header-close">
                    <i  class="icon iconfont icon-shoulishibaiicon fr"></i>
                </label>
            </div>

            <div v-if="chooseList.length>0" class="aui-content aui-margin-b-15 pt50">
                <div class="aui-list aui-media-list">
                    <div v-for="(item,index) in chooseList" class="aui-list-item" style="display: block;" >
                        <div class="aui-media-list-item-inner ptb " v-bind:class="{'border-bottomLine':index<chooseList.length-1}">
                            <div class="aui-list-item-inner aui-padded-t-10 aui-padded-b-10" style="display: block;">
                                <div class="aui-list-item-text">
                                    <div class="aui-list-item-title">
                                        {{item.text}}<span class="list-shu">|</span>{{item.modelno}}{{item.Unit}}
                                    </div>
                                    <div class="aui-list-item-right" style="width:160px;">
                                        <span v-on:click="delQuantity(item)"  class="new-jian-bg"> <i class="icon iconfont icon-jian  text-blue fz12 "></i></span>
                                        <a class="phone_a new-right">
                                            <input type="number" name="" v-model="item.Quantity" v-on:change="onChangeQuantity(item)" >
                                        </a>
                                        <span v-on:click="addQuantity(item)" class="new-jia-bg fr"><i class="icon iconfont icon-jia fff fz12"></i></span>
                                    </div>
                                </div>

                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <div class="aui_bottom">
            <div v-on:click="showChooseAll()" class="left-btn">
                <div class="aui-content-padded">
                    <p><i class="icon iconfont  icon-gouwulan- text-blue fz36"></i></p>
                    <div class="aui-badge">{{totalQuantity}}</div><Br />
                </div>
            </div>
            <div v-on:click="do_save()" class="right-btn">提交</div>
        </div>
    </div>
</body>
<script type="text/javascript" src="../script/api.js"></script>
<script type="text/javascript" src="../script/aui-toast.js"></script>
<script type="text/javascript" src="../script/aui-scroll.js"></script>
<script type="text/javascript" src="../script/vue.js"></script>
<script type="text/javascript" src="../script/config.js"></script>
<script type="text/javascript" src="../script/common.js"></script>
<script type="text/javascript" src="js/chooseckproduct.js"></script>

</html>
